home *** CD-ROM | disk | FTP | other *** search
/ MacTech 1 to 12 / MacTech-vol-1-12.toast / Source / MacTech® Magazine / Volume 07 - 1991 / 07.08 Aug 91 / Modeless SF Source / StarterIntf.p < prev   
Encoding:
Text File  |  1991-01-13  |  2.8 KB  |  159 lines  |  [TEXT/PJMM]

  1. {****************************************************}
  2. {}
  3. {        StarterIntf.p                                                                        }
  4. {}
  5. {        Interface file for the Starter application.                                        }
  6. {}
  7. {        Copyright © 1989, Symantec Corporation.  All rights reserved.            }
  8. {}
  9. {****************************************************}
  10.  
  11.  
  12. UNIT StarterIntf;
  13.  
  14. INTERFACE
  15.  
  16. USES
  17.     TCL, CSFDialogs;
  18.  
  19. CONST
  20.  
  21.     CSFOpenCmd = 9998;
  22.     CSFSaveCmd = 9999;
  23.  
  24.     dummyCmd = 2000;        { Used in example DoCommand methods     }
  25.     WINDStarter = 500;        { Resource ID for WIND template             }
  26.  
  27.  
  28. {****}
  29. { * CStarterApp}
  30. { *}
  31. { *    Application class for a typical application.}
  32. { *}
  33. { ****}
  34.  
  35. TYPE
  36.     CStarterApp = OBJECT(CSFApplication)
  37.  
  38.     { Declare your application's instance variables here     }
  39.     { (there are none in this example)                        }
  40.  
  41.     { CStarterApp's methods follow:                        }
  42.  
  43.             PROCEDURE IStarterApp;
  44.  
  45.             PROCEDURE SetUpFileParameters;
  46.             override;
  47.  
  48.             PROCEDURE SetUpMenus;
  49.             override;
  50.  
  51.             PROCEDURE DoCommand (theCommand: longint);
  52.             override;
  53.  
  54.             PROCEDURE UpdateMenus;
  55.             override;
  56.  
  57.             PROCEDURE CreateDocument;
  58.             override;
  59.  
  60.             PROCEDURE OpenDocument (macSFReply: SFReply);
  61.             override;
  62.  
  63.             PROCEDURE Exit;
  64.             override;
  65.  
  66.         END;
  67.  
  68.  
  69. {***}
  70. { * CStarterDoc}
  71. { *}
  72. { *    Document class for a typical application.}
  73. { *}
  74. { ***}
  75.  
  76. TYPE
  77.     CStarterDoc = OBJECT(CDocument)
  78.  
  79.     { Declare your document's instance variables here     }
  80.     { (there are none in this example)                        }
  81.  
  82.     { CStarterDoc's methods follow:                        }
  83.  
  84.                                     {* Construction/Destruction *}
  85.  
  86.             PROCEDURE IStarterDoc (aSupervisor: CApplication; printable: Boolean);
  87.             PROCEDURE Free;
  88.             override;
  89.  
  90.             PROCEDURE DoCommand (theCommand: longint);
  91.             override;
  92.  
  93.             PROCEDURE UpdateMenus;
  94.             override;
  95.  
  96.             PROCEDURE NewFile;
  97.             override;
  98.             PROCEDURE OpenFile (macSFReply: SFReply);
  99.             override;
  100.             PROCEDURE BuildWindow (theData: Handle);
  101.  
  102.                                     {* Filing *}
  103.  
  104.             FUNCTION DoSave: Boolean;
  105.             override;
  106.             FUNCTION DoSaveAs (macSFReply: SFReply): Boolean;
  107.             override;
  108.             PROCEDURE DoRevert;
  109.             override;
  110.         END;
  111.  
  112.  
  113.  
  114. {***}
  115. { * CStarterPane}
  116. { *}
  117. { *    Pane class for a typical application.}
  118. { *}
  119. { ***}
  120.  
  121. TYPE
  122.     CStarterPane = OBJECT(CPanorama)
  123.  
  124.     { Declare your pane's instance variables here             }
  125.     { (there are none in this example)                        }
  126.  
  127.     { CStarterPane's methods follow:                        }
  128.  
  129.                                     {* Construction/Destruction *}
  130.  
  131.             PROCEDURE IStarterPane (anEnclosure: CView; aSupervisor: CBureaucrat; aWidth, aHeight, aHEncl, aVEncl: integer; aHSizing, aVSizing: SizingOption);
  132.  
  133.                                     {* Drawing *}
  134.  
  135.             PROCEDURE Draw (VAR area: Rect);
  136.             override;
  137.  
  138.                                     {* Mouse *}
  139.  
  140.             PROCEDURE DoClick (hitPt: Point; modifierKeys: integer; when: longint);
  141.             override;
  142.             FUNCTION HitSamePart (VAR pointA, pointB: Point): Boolean;
  143.             override;
  144.  
  145.                                     {* Cursor *}
  146.  
  147.             PROCEDURE AdjustCursor (where: Point; mouseRgn: RgnHandle);
  148.             override;
  149.  
  150.                                     {* Scrolling *}
  151.  
  152.             PROCEDURE ScrollToSelection;
  153.             override;
  154.         END;
  155.  
  156.  
  157. IMPLEMENTATION
  158.  
  159. END.